<template>
    <div class="component-pover" :style='zIndexStyle'>
        <div x-arrow="" class="popperarrow"></div>
        <slot></slot>
    </div>
</template>

<script>

    import  { mapGetters, mapActions }  from 'vuex'
    import modal from './Modal.vue'
    import loading from '../components/Loading.vue'

    export default {
        components:{
            loading
        },
        props:{
            
        },
        data() {
            return {
                zIndex:10,
            }
        },
        computed:{
            ...mapGetters([
                'localInfo'
            ]),
             zIndexStyle(){
                return {zIndex:this.zIndex}
            }
        },
        methods:{
            ...mapActions([
                'setDocumentClick',
                'setSelectZIndex'
            ]),
            poverClose(){
                this.$emit('close')
            },
            poverConfrm(){
                this.$emit('confrm')
            },
        },

        watch: {
            
        }
    }
</script>

<style lang="scss" scoped>
    @import "../sass/variables";
    @import "../sass/extends";
    @import "../sass/mixins";
    .component-pover{
        margin-top:6px;
        padding:0;
        margin-left: 64px;
        width:128px;
        height:113px;
        background:rgba(255,255,255,1);
        box-shadow:0px 0px 0px rgba(0,0,0,0.2);
        border-radius:4px;
        //box-shadow:0px 7px 6px rgba(0,0,0,0.5);
        //border:1px solid #ebeef5;
        position:absolute;
    }

    .popperarrow {
        position: absolute;
        left:30px;
        top:-6px;
        width: 0;
        height: 0;
        border-color: transparent;
        border-width:6px;
        border-style: solid;
        border-top-width: 0;
        border-bottom-color: #ebeef5;
        border-left: 6px solid transparent;
        border-right: 6px solid transparent;
        border-bottom: 6px solid #ebeef5;
    }
     .popperarrow::after{
        top: 1px;
        content: " ";
        border-width: 6px;
        position: absolute;
        display: block;
        width: 0;
        height: 0;
        border-color: transparent;
        border-style: solid;
        margin-left: -6px;
        border-top-width: 0;
        border-bottom-color: #fff;
    } 
    .component-pover-footer{
        position: absolute;
        bottom:8px;
        left:0;
        width: 100%;
        height:20px;
    }
    .confrm,.close{
        width:49px;
        height:20px;
        text-align: center;
        line-height:20px;
        font-size: 14px;
        border-radius:8px;
        float: right;
        margin-right:10px;
        cursor: pointer;
    }
    .confrm{
        background:rgba(91,91,244,1);
        color:#fff;
    }
    .close{
        background:rgba(153,153,153,1);
        color:#fff;
    }
</style>